﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data.Entity;
using System.ComponentModel.DataAnnotations;

namespace BeanOverflow.Models
{
    public class Question
    {
        //Unique identifier 
        public int ID { get; set; }
        //Title of the question
        public string Title { get; set; }
        //Time the question was created
        public DateTime CreatedDate { get; set; }
        //Last time any of the questions fields was modified
        public DateTime LastModifiedDate { get; set; }
        //Question Body
        [DataType(DataType.MultilineText)]
        public string Body { get; set; }
        //name of user who created the question
        public string UserName { get; set; }
        //number of votes 
        public int Votes { get; set; }


    }
    public class QuestionDBContext : DbContext
    {
        public DbSet<Question> Questions { get; set; }
    }
}